<%@ page language="java" contentType="text/html; charset=UTF-8" import="java.util.*,Entity.*,Biz.*,javax.persistence.*"
    pageEncoding="UTF-8" %>
    <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>

        <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
        <html>

        <head>
            <!--Import Google Icon Font-->
            <link href="http://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
            <!--Import materialize.css-->
            <link type="text/css" rel="stylesheet" href="css/materialize.min.css" media="screen,projection" />

            <!--Let browser know website is optimized for mobile-->
            <meta name="viewport" content="width=device-width, initial-scale=1.0" />
            <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
            <title>学生界面</title>
        </head>

        <body>


            <% userBeanLocal _userBean=(userBeanLocal)session.getAttribute("_userBeanLocal"); User
                user=_userBean.getUser(); request.setAttribute("tubes", user.getPcrTubes()); %>
                <div class="container">
                    <div class="row">
                        <table>
                            <thead>
                                <tr>
                                    <th data-field="id">试管编号</th>
                                    <th data-field="status">状态</th>
                                    <th data-field="collect_time">采样时间</th>
                                    <th data-field="result_time">结果时间</th>
                                    <th data-field="users">被检测者</th>
                                </tr>
                            </thead>

                            <tbody>
                                <c:forEach items="${tubes}" var="tube">
                                    <tr>
                                        <td>${tube.id}</td>
                                        <td>
                                            ${tube.status}
                                            <c:if test="${tube.status eq 'no_result'} ">无结果</c:if>
                                            <c:if test="${tube.status eq 'negative'} ">阴性</c:if>
                                            <c:if test="${tube.status eq 'positive'} ">阳性</c:if>
                                        </td>
                                        <td>${tube.collect_time}</td>
                                        <td>${tube.result_time}</td>
                                        <td>${tube.users}</td>
                                    </tr>
                                </c:forEach>

                            </tbody>
                        </table>
                    </div>
                </div>


                <!--Import jQuery before materialize.js-->
                <script type="text/javascript" src="https://code.jquery.com/jquery-2.1.1.min.js"></script>
                <script type="text/javascript" src="js/materialize.min.js"></script>
        </body>

        </html>